1. Technical Field
This invention relates to a numerical control apparatus in which it is possible to control the start of execution of machine-side operations such as M, S, T and B functions.
2. Related Art
When using a numerical control (NC) apparatus for controlling a machine tool based on ordinary decoded NC commands, there are two known methods of executing commands when both a movement command and an operation command are issued from the same block. Specifically, in a first method, in which execution of a tool movement command starts at the same time as execution of an operation command (see FIG. 4). In a second method, the operation command is executed after execution of the movement command (see FIG. 5).
Of the first and second methods for controlling machine tools by NC commands, the first or second method is selected depending upon particulars of the operation to be performed by the machine tool. For example, among commands based on M-codes (auxiliary function codes), the operation command is output to the machine side using the first method with regard to M03, M04 and M05 (control for rotating and stopping a spindle) and the second method with regard to M20 and M21.
When an NC command for drilling a plurality of holes in a workpiece is delivered to the machine tool in this known numerical control apparatus, both a movement command for moving the tool to a predetermined position on the workpiece and an operation command for the drilling operation at this position are read and decoded by the numerical control apparatus from a single data block, and used to control the operation of the machine tool. If the first method mentioned above is adopted as the function for executing commands, it is required that coolant is supplied by a coolant start command executed at the same time that the tool is moved. If a long period of time is required to move the tool, coolant is wasted correspondingly. If the second method is adopted, on the other hand, start of coolant supply is commanded at the end of tool movement in response to execution of the movement command. When this is done, however, a time delay due to an exchange of signals between the numerical control apparatus and the machine tool is involved before the supply of coolant starts, and a great deal of time is wasted in the overall machining operation particularly in a case where the tool traveling distance on the workpiece is short.
In order to solve this problem which arises owing to the relationship between tool movement and the operation commanded on the machine side, in the prior art, the traveling distance commanded at the same time as the operation command on the machine side is limited to a fixed value, the distance required is commanded by being split between two data blocks, and the tool is moved by executing these commands in succession. Yet even in this case there is no essential solution to the problem; all that is done is to make the NC commands more complicated and place an extra burden upon the operator.